package com.molichuxing.services.business.dto.response;

import com.molichuxing.framework.dto.ResponseRootDto;

import lombok.Data;

/**
 * 台账查询付款周期dto
 * 
 * @author zoumingyu
 * @date 2019年9月5日
 *
 */
@Data
public class LedgerRepaymentPeriodBizDto extends ResponseRootDto {
	private static final long serialVersionUID = 7204891813143915570L;

	/**
	 * 订单号
	 */
	private Long orderCode;

	/**
	 * 排期号
	 */
	private Integer scheduleId;
	
	public LedgerRepaymentPeriodBizDto() {}
	
	public LedgerRepaymentPeriodBizDto(Long orderCode, Integer scheduleId) {
		this.orderCode = orderCode;
		this.scheduleId = scheduleId;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((orderCode == null) ? 0 : orderCode.hashCode());
		result = prime * result + ((scheduleId == null) ? 0 : scheduleId.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		LedgerRepaymentPeriodBizDto other = (LedgerRepaymentPeriodBizDto) obj;
		if (orderCode == null) {
			if (other.orderCode != null)
				return false;
		} else if (!orderCode.equals(other.orderCode))
			return false;
		if (scheduleId == null) {
			if (other.scheduleId != null)
				return false;
		} else if (!scheduleId.equals(other.scheduleId))
			return false;
		return true;
	}

}
